import java.io.File;
import java.io.IOException;
import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.List;


public class Main {
private static final String XMLFILE="users.xml";
private static final String DATA_PATH="data";
private static final String OUTPUT_PATH="output";
	public static void main(String[] args) {
//		//test saxparser
//		SaxParserUser spu = new SaxParserUser();
//		List<User> usersL=spu.parseFileAndGetListOfUsers(XMLFILE);
//		System.out.println(usersL.toString());
//		//read data files
//		DataFilesHandler handler= new DataFilesHandler(usersL, OUTPUT_PATH, DATA_PATH);
//		handler.processFileNamesAndSave();
//		
//		
		
		
////		String abc="www.sdf_skdf_d.txt";
//		String abc="20110912_103030_101.txt";
//		String [] a=abc.split("\\.");
//		for (String string : a) {
//			System.out.println(string);
//		}
		File f= new File("D:\\abc\\sdf\\df.gf");
			System.out.println(f.getParentFile());
			System.out.println(f.getPath());
		if(!f.exists()){
			System.out.println("not exists");
			f.mkdirs();
		}
		String time="20110525";
		SimpleDateFormat fromUser = new SimpleDateFormat("yyyyMMdd");
		SimpleDateFormat myFormat = new SimpleDateFormat("yyyy-MM-dd");
		try {
			System.out.println(myFormat.format(fromUser.parse(time)));
		} catch (ParseException e) {
			e.printStackTrace();
		}
		String time2="196725";
		SimpleDateFormat fromUser2 = new SimpleDateFormat("HHmmss");
		SimpleDateFormat myFormat2 = new SimpleDateFormat("hh:mm a");
		try {
			System.out.println(myFormat2.format(fromUser2.parse(time2)));
		} catch (ParseException e) {
			e.printStackTrace();
		}
	}
}
